#!/bin/bash
dir=$(cd `dirname $0`; pwd)/
# edit
container_name=cpdistance_train_0701
# train container
image_name=detectron2:10.2-cudnn7-devel-zh-cn
docker stop ${container_name}
docker rm ${container_name}
nvidia-docker run --name ${container_name} -it -v ${dir}:${dir} ${image_name} /bin/bash -c "export CUDA_VISIBLE_DEVICES=0 && python3 ${dir}src/train.py ${dir}config/train_config.yaml"
## for test
# python3 ${dir}src/train_net.py --eval-only --config-file ${dir}configs/COCO-Detection/faster_rcnn_R_50_FPN_1x.yaml OUTPUT_DIR ${dir}output MODEL.WEIGHTS ${dir}output/model_final.pth DATASETS.TEST ("coco_new_test",)
